import request from '@/utils/request'

// 查询训练方案
export function schemeList(query) {
    return request({
        url: '/training/scheme/list',
        method: 'post',
        params: query
    })
}
// 查询训练方案训练组列表
export function schemeDetails(id) {
    return request({
        url: '/training/scheme/schemeById?id='+id,
        method: 'post'
    })
}
// 增加训练方案详情
export function addScheme(data) {
    return request({
        url: '/training/scheme/add',
        method: 'post',
        data: data
    })
}
// 修改训练方案详情
export function editScheme(data) {
    return request({
        url: '/training/scheme/edit',
        method: 'post',
        data: data
    })
}
// 删除训练方案详情
export function deleteScheme(id) {
    return request({
        url: '/training/scheme/deleteById?id='+id,
        method: 'post'
    })
}

// 导出训练方案
export function exportScheme(query) {
    return request({
        url: '/training/scheme/export',
        method: 'get',
        params: query
    })
}